]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
workspacesView: Fix off-by-one error
authorAbderrahim Kitouni <akitouni@gnome.org>
Tue, 9 Feb 2021 09:17:29 +0000 (10:17 +0100)
committerMarge Bot <marge-bot@gnome.org>
Tue, 9 Feb 2021 09:40:29 +0000 (09:40 +0000)
This is basically 9f0e7632a6 ported over ed1170906b which was dropped this
fix when copying things around.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1655>

js/ui/workspacesView.js

index 56b5e55edad233e2972804873415ddbfcd4c7d11..9ac7b6a6579785da6c78abb92858f1ca50476d59 100644 (file)
@@ -167,7 +167,7 @@ class WorkspacesView extends WorkspacesViewBase {
         const rtl = this.text_direction === Clutter.TextDirection.RTL;
         const adj = this._scrollAdjustment;
         const currentWorkspace = vertical || !rtl
-            ? adj.value : adj.upper - adj.value;
+            ? adj.value : adj.upper - adj.value - 1;
 
         // Single fit mode implies centered too
         let x1 = 0;